package com.demo.handler;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.jfinal.handler.Handler;

public class HtmlHandler extends Handler {

	@Override
	public void handle(String target, HttpServletRequest request,
			HttpServletResponse response, boolean[] isHandled) {
		System.out.println("执行handler HtmlHandler  target:" + target);
		int index = target.lastIndexOf(".html");
		if (index != -1)
			target = target.substring(0, index);
		next.handle(target, request, response, isHandled);
	}

}
